package com.wumao.service;

import com.wumao.pojo.Tag;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import java.util.List;

/**
 * @author Gaowumao
 * @Decripted
 * @Email none-j@qq.com
 * @create 2021-04-16 15:48
 */
public interface TagService {

    /*实现标签的增删改查*/

    Tag addTag(Tag tag);
    /*通过ID查询Tag*/
    Tag getTag(Long id);

    /*分页查询标签*/
    Page<Tag> listTag(Pageable pageable);

    void deleteTag(Long id);

    List<Tag> listTags();

    List<Tag> listTagTop(Integer size);

    List<Tag> listTags(String ids);

    /*通过名称查询Tag*/
    Tag getTagByName(String name);

    /*先查找到Tag再修改*/
    Tag updateTag(Long id,Tag tag);

}
